<#assign menuId=4>
<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>大货详情-${Application.systemName!}</title>
    <meta content='width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no' name='viewport'>
    <!-- bootstrap 3.0.2 -->
    <link href="../css/bootstrap.min.css" rel="stylesheet" type="text/css" />
    <!-- font Awesome -->
    <link href="../css/font-awesome.min.css" rel="stylesheet" type="text/css" />
    <!-- Ionicons -->
    <link href="../css/ionicons.min.css" rel="stylesheet" type="text/css" />
    <!-- Theme style -->
    <link href="../css/AdminLTE.css" rel="stylesheet" type="text/css" />
    <!--datepicker-->
    <link type="text/css" href="../css/datepicker/datepicker3.css"/>
    <link href="../css/myself.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="../js/lib/jquery.min.js"></script>
    <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
    <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
    <script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js"></script>
    <![endif]-->
    <style type="text/css">
        *{
            margin: 0;
            padding: 0;
        }
        ul li{
            list-style: none;
            margin-top: 10px;
        }
        .navbar-nav > .user-menu > .dropdown-menu > li.user-header {
		    margin: 0;
		}
        .people li{
       		float: left;
       		width: 25%;
       		margin-bottom: 10px;
       	}
        .marginTOP10, .custormView{
   			margin-top: 10px; 
   		}
   		.marginTOP10:nth-child(1) {
   			margin-top: 20px;
   		}
   		.conter_jiben{
   			margin-bottom: 10px;
   		}
       
		.bold{
			font-size: 14px;
			font-weight: bold;
		}
        .pull-left{
            border-left: 6px solid #3882FF;
            padding: 0 5px;
        }
     
        .red{
            color: red;
        }
        .clear{
            clear: both;
            width: 100%;
            height: 1px;

        }
        .breadcrumb>span{
            margin-right: 20px;
        }
        .six-font{
            font-size: 14px;
        }
        .six-font>span{
            font-size: 16px;
        }
        .clearfix>span>a{
            margin-left: 10px;
            margin-top: 1px;
            float: left;
        }
        .pull-left {
            border-left: 6px solid #3882FF;
            padding: 0 5px;
        }
        input[type="checkbox"]{margin-right: 5px;}
        .right-text .pull-right:last-child{margin-right: 3rem;}
        .table .r_pic{width: 70px;height: 70px;display: inline-block;border: 1px solid black;}
        .left-text span{margin-right: 10px;}
        .progressChart{width: 100%;margin: 20px 0;}
        .progressChart .chart_item{}
        .progressChart .chart_item:first-child >div{width: 90px;float:left;text-align: center;}
        .progressChart .chart_item:first-child {margin-left: 12%;height: 20px;}
        .progressChart .content_left{width: 100%;height: 90px;background: #ddd;text-align: center;margin-bottom: 10px;}
        .progressChart .content_left img{width: 90%;height: 60px;margin: 0 auto;background: white;display: block;margin-top: 3px;}
        .progressChart .content_left p{background: #ddd;}
    	
    	.progressChart .table{
    		margin: 0;
    	}
    	.progressChart .unit{
    		width: 30px;
    		height: 30px;
    		border-radius: 50%;
    		background: #e4e4e4;
    		position: relative;
    	}
    	.progressChart .unit .unit1{
    		width: 20px;
    		height: 20px;
    		border-radius: 50%;
    		background: #13c68f;
    		position: absolute;
    		top: 50%;
    		left: 50%;
    		margin-top: -10px;
    		margin-left: -10px;
    		z-index: 3;
    	}
    	.progressChart .unit_td{
    		position: relative;
    	}
    	.progressChart .unit2{
    		width: 100%;
    		height: 15px;
    		background: #e4e4e4;
    		position: absolute;
    		top: 50%;
    		left: 0;
    		margin-left: 10%;
    		margin-top: -7.5px;
    	}
    	.progressChart .unit2 .unit2_1{
    		width: 100%;
    		height: 7.5px;
    		background: #13c68f;
    		position: absolute;
    		top: 50%;
    		margin-left: 10%;
    		margin-top: -3.5px;
    		z-index: 8;
    	}
    	.progressChart .time_line td{
    		color: #bbb;
    		font-weight: bold;
    	}
    	.progressChart {
		    width: 96%;
		    margin: 20px;
		}
    	/*新增样式*/
		.ol_left{
            width: 100%;
            height: 30px;
            line-height: 30px;
            padding: 0;
        }
        .ol_left>li{
            float: left;
            margin-right: 5px;
        }
        .ol_left li, .ol_left{
        	margin-bottom: 0;
        }
    	.down_load img{
			width: 60px;
			height: 60px;
			border-radius: 6px;    		
    	}
    	.down_load div:nth-child(2){
    		font-size: 12px;
    	}
    	/* 弹出大图样式 */
			.Image{
				width: 960px;
			}
			.Image .modal-body {
				position: relative;
			}
			.Image .modal-body img{
				width: 100%;
				height: 540px;
				cursor: pointer;
				position: absolute;
				top: 0;
				left: 0;
				z-index:99;
			}
			.iconR, .iconL{
				position: absolute;
				top: 50%;
				font-size: 50px;
				color: #3882ff;
				cursor: pointer;
				opacity: 0.7;
				margin-top: 20%;
				z-index:2000;
			}
			.iconL{
				left: 10px;
			}
			.iconR{
				right: 10px;
			}
			.tc2_content1_d2{
                width: 90px;
                height: 30px;
                background-color: #5f6571;
                color: #fff;
                text-align: center;
                line-height: 30px;
                border-radius: 15px 0 0 15px;
                position: absolute;
                right: 0;
                top: 20px;
                font-weight: bold;
                z-index:999;
            }
            
            .left-side{
            	display: block;
            }
    </style>
</head>
<body class="skin-blue">
<!-- header logo: style can be found in header.less -->
<#include "../header.html"/>

<div class="wrapper row-offcanvas row-offcanvas-left">
    <!-- Left side column. contains the logo and sidebar -->
    <#include "../menu.html"/>
    <aside class="right-side">
        <section class="content-header">
            <h1 >创建大货订单
                <!--<small><a href="#">返回</a></small>-->
            </h1>
            <div class="clear"></div>
            <ol class="ol_left">
                <li>当前位置：</li>
                <li><a href="list?pageNo=1">大货订单</a></li>
                <li>> 订单详情</li>
            </ol>
			<hr class="no-margin" />
        </section>
        <!-- Content Header (Page header) -->
        <section class="content">
            <div class="row">
                <div class="col-md-12">
                    <div class="box" style="padding: 20px;">
                    	
                        <div class="clearfix center">
                            <span class="pull-left bold">进度状态</span>
                        </div>
                        <div class="center clearfix progressChart">
                        	<table class="table center no-border">
                        		<tr>
                        			<th width="12%"></th>
                        			<th width="11%">下达大货通知单</th>
                        			<th width="11%">上传推码表</th>
                        			<th width="11%">生产起始日</th>
                        			<th width="11%">生产完成日</th>
                        			<th width="11%">尾查</th>
                        			<th width="11%">填写装箱单</th>
                        			<th width="11%">收货时间</th>
                        			<th width="11%">截止时间</th>
                        		</tr>
                        		<#list productionOrderResult.productionPatternResults as productionPatternResult>
                        		<tr>
                        			<td>
                        				<div class="fl content_left">
	                                    	<img>
	                                    	<p>子订单号：</p>
		                                    <p>${productionPatternResult.code!}</p>
		                                </div>
                        			</td>
                        			<td colspan="8">
                        				<table class="table no-border">
                        					<tr>
                        						<td class="unit_td">
                        							<div class="unit">
		                                                <div class="unit unit1"></div>
		                                           	</div>
		                                           	<div class="unit2">
		                                           		<div class="unit2_1"></div>
		                                           	</div>
                        						</td>
                        						<td class="unit_td">
                        							<div class="unit">
		                                                <div class="unit unit1"></div>
		                                           	</div>
		                                           	<div class="unit2">
		                                           		<div class="unit2_1"></div>
		                                           	</div>
                        						</td>
                        						<td class="unit_td">
                        							<div class="unit">
		                                                <div class="unit unit1"></div>
		                                           	</div>
		                                           	<div class="unit2">
		                                           		<div class="unit2_1"></div>
		                                           	</div>
                        						</td>
                        						<td class="unit_td">
                        							<div class="unit">
		                                                <div class="unit unit1"></div>
		                                           	</div>
		                                           	<div class="unit2">
		                                           		<div class="unit2_1"></div>
		                                           	</div>
                        						</td>
                        						<td class="unit_td">
                        							<div class="unit">
		                                                <div class="unit unit1"></div>
		                                           	</div>
		                                           	<div class="unit2">
		                                           		<div class="unit2_1"></div>
		                                           	</div>
                        						</td>
                        						<td class="unit_td">
                        							<div class="unit">
		                                                <div class="unit unit1"></div>
		                                           	</div>
		                                           	<div class="unit2">
		                                           		<div class="unit2_1"></div>
		                                           	</div>
                        						</td>
                        						<td class="unit_td">
                        							<div class="unit">
		                                                <div class="unit unit1"></div>
		                                           	</div>
		                                           	<div class="unit2">
		                                           		<div class="unit2_1"></div>
		                                           	</div>
                        						</td>
                        						<td class="unit_td">
                        							<div class="unit">
		                                                <div class="unit unit1"></div>
		                                           	</div>
                        						</td>
                        					</tr>
                        					<tr class="time_line">
                        					
                        						<td>
                        						<#list productionPatternResult.orderTaskPerformers as performer>
                        						<#if performer.action=='F300'>
                        						${performer.createdAt?string("MM月dd日")}
                        						<br>
                        						${performer.createdAt?string("HH:mm")}
                        						<#break>
                        						</#if>                       
                        						
                        						</#list></td>
                        						
                        						
                        						<td>
                        						<#list productionPatternResult.orderTaskPerformers as performer>
                        						<#if performer.action=='F301'>
                        						${performer.createdAt?string("MM月dd日")}
                        						<br>
                        						${performer.createdAt?string("HH:mm")}
                        						<#break>
                        						</#if>                       
                        						
                        						</#list>
                                                 </td>
                        						
                        						<td><#if productionPatternResult.produceStartdate??>${productionPatternResult.produceStartdate?string("MM月dd日")}</#if>
                        						<br>
                        						<#if productionPatternResult.produceStartdate??>${productionPatternResult.produceStartdate?string("HH:mm")}</#if>
                        						</td>
                        						<td><#if productionPatternResult.produceEnddate??>${productionPatternResult.produceEnddate?string("MM月dd")}</#if>
                        						<br>
                        						<#if productionPatternResult.produceEnddate??>${productionPatternResult.produceEnddate?string("HH:mm")}</#if>
                        						</td>
                        						<td><#if productionPatternResult.lastCheckTime??>${productionPatternResult.lastCheckTime?string("MM月dd")}</#if>
                        						<br>
                        						<#if productionPatternResult.lastCheckTime??>${productionPatternResult.lastCheckTime?string("HH:mm")}</#if></td>
                        						<td><#list productionPatternResult.orderTaskPerformers as performer>
                        						<#if performer.action=='F303'>
                        						${performer.createdAt?string("MM月dd日")}
                        						<br>
                        						${performer.createdAt?string("HH:mm")}
                        						<#break>
                        						</#if>                       
                        						
                        						</#list>
                                           </td>
                        						<td><#list productionPatternResult.encasements as encasement>
                        						<#if encasement.arriveDate??>${encasement.arriveDate?string("MM月dd日")}</#if>
                                                    <br>
                                                    <#if encasement.arriveDate??>${encasement.arriveDate?string("HH:mm")}</#if>
                                                    <#break>
                                           </#list>
                                           </td>
                        						<td>
                                                    <#if productionPatternResult.deliveryDate??>${productionPatternResult.deliveryDate?string("MM月dd日")}</#if>
                                              <br>
                                              <#if productionPatternResult.deliveryDate??>${productionPatternResult.deliveryDate?string("HH:mm")}</#if>
                                                    </td>
                        					</tr>
                        				</table>
                        			</td>
                        		</tr>
                        		</#list>
                        		
                        		
                        	</table>
                        </div>
                        <div class="clearfix center" style="vertical-align: middle;">
                            <span class="pull-left bold">订单详情</span>
                            <a href="javascript:;" class="bule-border">查看详细</a>
                        </div>
                        <div class="center conter clearfix">
                                <div class="conter_jiben col-md-12 marginTOP10 bold no-padding">订单基本信息</div>
                                <table class="table table-bordered">
                                    <tr>
                                        <td class="text-center no-border" width="10%">订单编号: </td>
                                        <td class="no-border" width="40%">${productionOrderResult.code}</td>
                                        <td class="text-center no-border" width="10%">订单创建时间: </td>
                                        <td class="no-border" width="40%">${productionOrderResult.createAt?string("yyyyMMdd HH:mm")}</td>
                                    </tr>
                                    <tr>
                                    	<td class="text-center no-border" width="10%">销&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;售: </td>
                                    	<td colspan="3" class="no-border" width="90%">${productionOrderResult.creatorZh!}</td>
                                    </tr>
                                </table>
                                <div class="conter_jiben col-md-12 bold no-padding">客户信息</div>
                                <table class="table table-bordered">
                                    <tr>
                                        <td class="text-center" width="10%" >
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">客户编号</td></tr>
                                        		<tr><td style="border: 0;">客户名称</td></tr>
                                        		<tr><td style="border: 0;">客户分类</td></tr>
                                        		<tr><td style="border: 0;">网&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;址</td></tr>
                                        		<tr><td style="border: 0;">备&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;注</td></tr>
                                        	</table>

                                        </td>
                                        <td width="40%">
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.code!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.fullname}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.category!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.web!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.memo!}</td></tr>
                                        	</table>
                                        </td>
                                        <td class="text-center" width="10%">
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">客户等级</td></tr>
                                        		<tr><td style="border: 0;">客户简称</td></tr>
                                        		<tr><td style="border: 0;">公司地址</td></tr>
                                        		<tr><td style="border: 0;">收件地址</td></tr>
                                        	</table>
                                        </td>
                                        <td width="40%">
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.level!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.abbreviation!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.province!} ${productionOrderResult.customer.city!} ${productionOrderResult.customer.area!} ${productionOrderResult.customer.detailAddress!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.deliveryAddress!}</td></tr>
                                        	</table>
                                        </td>
                                    </tr>
                                    <#list productionOrderResult.customer.contacts as contact>
                                    <tr>
                                        <td class="text-center">
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">联系人姓名</td></tr>
                                        		<tr><td style="border: 0;">邮&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;箱</td></tr>
                                        	</table>
                                        </td>
                                        <td>
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">&nbsp;${contact.linkman!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${contact.email!}</td></tr>
                                        	</table>
                                        </td>
                                         <td class="text-center">
                                         	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">联系方式</td></tr>
                                        		<tr><td style="border: 0;">职位/部门</td></tr>
                                        	</table>
                                        </td>
                                        <td>
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">&nbsp;${contact.contact!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${contact.deptPosition!}</td></tr>
                                        	</table>
                                        </td>
                                    </tr>
                                    </#list>
                                </table>
                                <div class="col-md-12 marginTOP10 bold no-padding" style="margin-bottom: 10px">产品信息</div>
                                <table class="table table-bordered">
                                    <tr>
                                        <td class="text-center" width="">
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">产品品类</td></tr>
                                        		<tr><td style="border: 0;">附&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;件</td></tr>
                                        	</table>
                                        </td>
                                        <td width="40%">
                                        	<table class="table no-margin no-padding">
                                        		<tr>
	                                        		<td style="border: 0;">&nbsp;
	                                        			<#if productionOrderResult.customer.productCategory?size!=0>
					                    				<#list productionOrderResult.customer.productCategory as productCategory>
					                    					 ${productCategory} 
					                    				</#list>
					                    				<#else>/
					                    				</#if>
	                                        		</td>
                                        		</tr>
                                        		<tr>
                                        			<td style="border: 0;">&nbsp;
                                        				<#if productionOrderResult.customer.attachment?size!=0>
					                    				<#list productionOrderResult.customer.attachment as attach>
					                    				
					                    				<span id="fileName1">${attach.originName!}</span>
					                    				<a href="../businessfile/downFile?businessFileId=${attach.id!}" class="down"><i class="iconfont down-i"></i>点击下载</a>	
					                    				
					                    				
					                    				
					                    				<!-- ${attach.businessFile?substring(13)}<a href="../customer/downFile?filename=${attach.businessFile}">点击下载</a> -->
					                    				</br>
					                    				</#list>
					                    				<#else>/
					                    				</#if>
                                        			</td>
                                        		</tr>
                                        	</table>
                                        </td>
                                        <td class="text-center" width="10%">
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">风格</td></tr>
                                        	</table>
                                        </td>
                                        <td width="40%">
                                        	<table class="table no-margin no-padding">
                                        		<tr>
                                        			<td style="border: 0;">
                                        				<#if productionOrderResult.customer.styleLabel?size!=0>
						                    			<#list productionOrderResult.customer.styleLabel as styleLabel>
						                    				<span class="biaoqian">${styleLabel!}</span>
						                    			</#list>
						                    			<#else>/
						                    			</#if>
                                        			</td>
                                        		</tr>
                                        	</table>
                                        </td>
                                    </tr>
                                </table>
                                <div class="conter_jiben col-md-12 marginTOP10 bold no-padding">销售信息</div>
                                <table class="table table-bordered">
                                    <tr>
                                        <td class="text-center" width="10%">
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">目标人群</td></tr>
                                        		<tr><td style="border: 0;">销售价格</td></tr>
                                        		<tr><td style="border: 0;">上新频率</td></tr>
                                        	</table>
                                        </td>
                                        <td width="40%">
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.targetConsumer!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.salePrice!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.updateFrequency!}</td></tr>
                                        	</table>
                                        </td>
                                        <td class="text-center" width="10%">
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">销&nbsp;&nbsp;&nbsp;&nbsp;售&nbsp;&nbsp;&nbsp;&nbsp;渠&nbsp;&nbsp;&nbsp;&nbsp;道</td></tr>
                                        		<tr><td style="border: 0;">预计年销售额</td></tr>
                                        		<tr><td style="border: 0;">上&nbsp;&nbsp;&nbsp;&nbsp;新&nbsp;&nbsp;&nbsp;&nbsp;数&nbsp;&nbsp;&nbsp;&nbsp;量</td></tr>
                                        	</table>
                                        </td>
                                        <td width="40%">
                                        	<table class="table no-margin no-padding">
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.saleChannel!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;${productionOrderResult.customer.saleAmount!}</td></tr>
                                        		<tr><td style="border: 0;">&nbsp;
                                        		<#if productionOrderResult.customer.updateCount??>
                                        		${productionOrderResult.customer.updateCount!}款/次
                                        		</#if>
                                        		</td></tr>
                                        	</table>
                                        </td>
                                    </tr>
                                </table>
                                <div class="conter_jiben col-md-12 marginTOP10 bold no-padding">客户需求</div>
                                <table class="table table-bordered">
                                    <tr>
                                        <td class="text-center" width="10%"> 需求描述</td>
                                        <td width="90%">&nbsp;
                                           ${productionOrderResult.requirement!}
                                        </td>
                                    </tr>
                                </table>
                            </div>
                        <table class="table center text-center table-bordered custormView">
                            <tr>
                                <td width="10%">订单号</td>
                                <td width="40%">${productionOrderResult.code!}</td>
                                <td clas="text-center" width="10%">订单创建时间</td>
                                <td width="40%">${productionOrderResult.createAt?string("yyyy-MM-dd HH:mm")}</td>
                            </tr>
                            <tr>
                                <td>截止时间</td>
                                <td><#if productionOrderResult.enddate??>${productionOrderResult.enddate?string("yyyy-MM-dd")}</#if></td>
                                <td  clas="text-center" rowspan="2">客户合同</td>
                                <td rowspan="2" class="down_load">
                                	<div class="pull-left no-border">
                                		<a   data-toggle="modal" data-target="#uploadModal"><img src="../img/file.png"/></a>
                                	</div>
                                	<div>
                                	 <#if productionOrderResult.saleContactFiles?size gt 0>
                                	<#list productionOrderResult.saleContactFiles as saleContactFile>
                                		<p class="no-margin">${saleContactFile.originName!}</p>
                                    	<p class="no-margin">
                                    		<a href="../businessfile/downFile?businessFileId=${saleContactFile.id}">下载</a>
                                    	</p>
                                    </#list>	
                                   
                                    </#if>
                                     <p class="no-margin">
                                    		<div class="modal fade" id="uploadModal"  tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
									
				<div class="modal-dialog">
					<div class="modal-content">
						<div class="modal-header">
							<button type="button" class="close" data-dismiss="modal" aria-hidden="true">
								&times;
							</button>
							<h4 class="modal-title" id="myModalLabel">
								上传客户合同
							</h4>
						</div>
						<div class="modal-body">
							<form class="form-horizontal" id="contactFileForm" role="form" >

  					<div class="form-group">
                  <div class="col-sm-10">
                    <input class="form-control" name="contactFile"  value="" type="file">
                  </div>
                </div>
                
			            </form>	
						</div>
						<div class="modal-footer">
							<button type="button" onclick="uploadSaleContactFile();" class="btn btn-primary">确定
							</button>
							<button type="button" class="btn btn-default" data-dismiss="modal">
								取消
							</button>
						</div>
					</div><!-- /.modal-content -->
				</div><!-- /.modal -->
			</div>
                                    	</p>
                                	</div>
                                    
                                </td>
                            </tr>
                            <tr>
                                <td>最终报价</td>
                                <td>/</td>
                            </tr>
                            <tr>
                                <td>客户需求</td>
                                <td colspan="3">${productionOrderResult.requirement!}</td>
                            </tr>
                        </table>
                        <div class="clearfix center" style="margin-top: 20px">
                            <span class="pull-left bold">大型货款</span>
                        </div>
                        <#assign cnt = 0/>
                        <#list productionOrderResult.productionPatternResults as productionPatternResult>
                        <#if productionPatternResult.status == 30>
                           <#assign cnt = cnt +1/>
                           </#if>
                        </#list>
                        <#if cnt gt 0>
                        <div class="clearfix center">
                            <span style="margin: 10px 20px 0 0;">
                                <input id="check-all" type="checkbox" />&nbsp;&nbsp;全选
                            </span>
                            <button onclick="openNotice()" style="margin-right: 10px;" class="btn btn-primary btn-sm">填写生产通知单</button>
                            
                        </div>
                        </#if>
                        <#list productionOrderResult.productionPatternResults as productionPatternResult>
                        <table class="table center table-bordered custormView">
                            <tr>
                                <td colspan="2"  class="left-text" style="font-weight: bold">
                                <#if productionPatternResult.status == 30>
                                    <input  type="checkbox"  name="chk" value="${productionPatternResult.id!}">
                                    </#if>
                                    <span>${productionOrderResult.createAt?string("yyyy-MM-dd")}</span>
                                    <span>订单号：${productionPatternResult.code!}</span>
                                     
                                        	<#if (Session["permisionMap"]["F308"]??)>
										<a href="../orderpattern/showEditPage?id=${productionPatternResult.orderPatternId}&productionOrderId=${productionOrderResult.id}" class="fr bule-border">编辑设计稿</a>
                                            
										</#if>
											 <a href="../orderpattern/detail?id=${productionPatternResult.orderPatternId}&productionOrderId=${productionOrderResult.id}" class="fr bule-border">查看明细</a>
                                    
                                   <span class="red fr record">	<#if productionPatternResult.status==30>待安排<#elseif productionPatternResult.status==31>待推码
				                		<#elseif productionPatternResult.status==32>生产中<#elseif productionPatternResult.status==32>待发货<#elseif productionPatternResult.status==34>待签收<#elseif productionPatternResult.status==99>已完成</#if>
				                		</span>
                                </td>
                            </tr>
                            <tr>
                                <td width="60%">
                                    <span class="Design_draft"><img src="${Application.accessFileUrl}${productionPatternResult.mainImage!}" alt=""  onclick="showImage('${productionPatternResult.orderPatternId!}','${productionPatternResult.mainImage!}')" data-toggle="modal" data-target="#show_image"/></span>
                                </td>
                                <td class="rel" style="vertical-align: top;"> 
                                    <i class="design-icon"></i>
                                    <div class="design-text">
                                        <p>设计编号：<span>${productionPatternResult.code!}<span></p>
                                        <p>款号：<span>${productionPatternResult.patternNo!}</span></p>
                                        <p>年份：<span>${productionPatternResult.period!}</span></p>
                                        <p>季节：<span>${productionPatternResult.season!}</span></p>
                                        <p>性别：<span>${productionPatternResult.sex!}</span></p>
                                        <#list productionPatternResult.styleLabels as styleLabel>
                                        <span class="bule-border">${styleLabel.name!}</span>
                                        </#list>
                                    </div>
                                </td>
                            </tr>
                            <tr>
                                <td colspan="2" style="text-align: center; background: rgb(246,246,246); vertical-align: middle;" class="clearfix left-text">
                                    <span class="fl">生产数量${productionPatternResult.produceCnt!}件</span>
                                    <!-- <button class="btn btn-primary fr">安排工厂</button> -->
                                    <#if (Session["permisionMap"]["F307"]??)  && productionPatternResult.status gt 30>
                                    <a style="margin-right: 10px;" href="../productionorder/downPdf?ids=${productionPatternResult.id}" class="btn btn-primary btn-sm fr">下载生产通知单</a>
                            </#if>
                              <#if (Session["permisionMap"]["F300"]??) >
                                   <#if productionPatternResult.status lt 99>
                                    <a style="margin-right: 10px;" href="addProductionNotice?ids=${productionPatternResult.id}" class="btn btn-primary btn-sm fr">填写通知单</a>
                                 
                                    </#if>
                            </#if>
                            <button style="margin-right: 10px;" class="btn btn-primary btn-sm fr" onclick="location.href='../encasement/detail?productionPatternId=${productionPatternResult.id!}';">下载装箱单</button>
                            
                            <#list productionPatternResult.contactFiles as contactFile>
                                		<#if contactFile_index==0>
                                    	 <a  href="../businessfile/downFile?businessFileId=${contactFile.id}" style="margin-right: 10px;" class="btn btn-primary btn-sm fr">下载工厂合同</a>
                                    <#break>
                                    </#if>
                                    </#list>	
                            
                                </td>
                            </tr>
                        </table>
                        </#list>
                        
                    </div><!-- /.box -->

    </aside><!-- /.right-side -->
    <!-- Right side column. Contains the navbar and content of the page -->

	<div class="modal fade" id="show_image" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
		<div class="modal-dialog Image">
			<div class="modal-content">
				<div class="modal-body">
					<!-- <img src="../images/Design_draft_03.jpg" alt="" />
					<img src="../images/Design_draft_03.jpg" alt="" /> -->
					<!-- <div class="iconR">&lt;</div>
					<div class="iconL">&gt;</div> -->
					<i class="fa fa-chevron-right iconR"></i>
					<i class="fa fa-chevron-left iconL"></i>
					<div class="tc2_content1_d2">&lt;   <span id="num">1</span>  /   <span id="max">1</span>   &gt;</div>
				</div>
			</div><!-- /.modal-content -->
		</div><!-- /.modal -->
	</div>
			
</div><!-- ./wrapper -->


<!-- jQuery 2.0.2 -->
<script src="../js/jquery.min.js"></script>
<!-- Bootstrap -->
<script src="../js/bootstrap.min.js" type="text/javascript"></script>
<!-- AdminLTE App -->
<script src="../js/AdminLTE/app.js" type="text/javascript"></script>
 <script src="../js/jquery.form.min.js"></script>
</body>
<script type="text/javascript">
function openNotice(){
	var ids = "";
	var objs = document.getElementsByName("chk");
	for(var i =0;i<objs.length;i++){
		if(objs[i].checked==true){
			ids = ids +objs[i].value+",";
		}
	}
	if(ids==""){
		alert("请先选择款式");
		return;
	}
	if(ids !=""){
		ids = ids.substring(0, ids.length-1);
		window.location.href="addProductionNotice?ids="+ids+"&productionOrderId=${productionOrderResult.id}";
	}
}
function uploadSaleContactFile(id){
	$("#contactFileForm").ajaxSubmit({  
        type : "POST",  //
        url : "saveSaleContact?id=${productionOrderResult.id}",
        data : {  
        	
        },
        success : function(map) {

        	if(map.head.respCode=="0000000"){
            	success("提交成功",function(){
            		window.location.href="detail?id=${productionOrderResult.id}";
            	});
            	
            }else{
            	alert("22");
            }
        }  
    }); 
}
 $("#check-all").on('ifUnchecked', function(event) {
     //Uncheck all checkboxes
     $("input[type='checkbox']", ".custormView").iCheck("uncheck");
 });
 //When checking the checkbox
 $("#check-all").on('ifChecked', function(event) {
     //Check all checkboxes
     $("input[type='checkbox']", ".custormView").iCheck("check");
 });
	
 $(function(){
	 $('.conter').hide();
	 $('.conter').prev().children('a').click(toggleConter);
 })
 
 function toggleConter(){
	 $('.conter').toggle();
	 if($('.conter').css('display')=='none')
		 $(this).html('查看详细');
	 else
		 $(this).html('收起');
 }
 
 /* 弹出图片框鼠标悬浮事件 */
 $('.iconR').hide();
	$('.iconL').hide();
 
 $( ".Image" ).hover(
	  function() {  
		  $('.iconR').show();
		    $('.iconL').show();  
		  }, function() {  
			  $('.iconR').hide();
			    $('.iconL').hide(); 
		  } 
	); 
	
	function showImage(id,main){
 	$.ajax({
 		url:'../orderpattern/showImage',
 		type:'get',
 		data:{orderPatternId:id},
 		dataType:'json',
 		async:false,
 		success:function(result){
 			if(result.head.respCode='0000000'){
 				var image=result.body;
 				var div=$('#show_image').find('.modal-body');
 				div.find('img').remove();
 				div.find('#max').html(image.length);
 				for(var i=0;i<image.length;i++){
 					var path='${Application.accessFileUrl}'+image[i];
 					var img=$('<img src="'+path+'"></img>');
 					div.find('.iconR').before(img);
 					img.hide();
 					if(image[i]==main){
 						div.find('#num').html(i+1);
 						img.show();
 					}
 				}
 				div.find('.iconR').click(next);
 				div.find('.iconL').click(last);
 			}
 		}
 	});
 }
 function next(){
 	var span=$(this).parent().find('#num');
 	var num=span.html();
 	num=parseInt(num);
 	var max=$(this).parent().find('#max').html();
 	if(num==max) return;
 	$(this).parent().find('img').eq(num).show();
 	$(this).parent().find('img').eq(num-1).hide();
 	span.html(++num);
 }
 
 function last(){
 	var span=$(this).parent().find('#num');
 	var num=span.html();
 	num=parseInt(num);
 	if(num==1) return;
 	$(this).parent().find('img').eq(num-2).show();
 	$(this).parent().find('img').eq(num-1).hide();
 	span.html(num-1);
 }
   
</script>
</html>
